package event.mouse;

import java.awt.event.MouseEvent;
import java.awt.event.MouseListener;
import java.awt.event.MouseMotionListener;

public class MouseEventListener implements MouseListener, MouseMotionListener {
    // 鼠标单击
    @Override
    public void mouseClicked(MouseEvent e) {
        System.out.println("鼠标单击");
    }

//    鼠标被按下
    @Override
    public void mousePressed(MouseEvent e) {
        System.out.println("鼠标被按下");
    }

//    鼠标被抬起
    @Override
    public void mouseReleased(MouseEvent e) {
        System.out.println("鼠标被抬起");
    }

//    鼠标的进入
    @Override
    public void mouseEntered(MouseEvent e) {
        System.out.println("鼠标的进入");
    }

//    鼠标离开
    @Override
    public void mouseExited(MouseEvent e) {
        System.out.println("鼠标离开");
    }

//    鼠标拖动
    @Override
    public void mouseDragged(MouseEvent e) {
        System.out.println("鼠标拖动");
    }

//    鼠标移动
    @Override
    public void mouseMoved(MouseEvent e) {
        System.out.println("鼠标移动");
    }
}
